package cn.zlb.frame.adapter.controller.merchant;

import cn.zlb.frame.adapter.controller.merchant.vo.MerchantCreateRespVO;
import cn.zlb.frame.adapter.controller.merchant.vo.MerchantCreateVO;
import cn.zlb.frame.common.result.Result;
import cn.zlb.frame.common.result.ResultBuilder;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

import java.util.Objects;

/**
 * @author yangjie.deng@resico.cn
 * @date 2023-11-09 10:37:18
 * @describe class responsibility
 */
@RestController
public class MerchantController {

    @PostMapping("createCompany")
    public Result<MerchantCreateRespVO> createCompany(@RequestBody @Validated MerchantCreateVO merchantCreate) {
        if (Objects.isNull(merchantCreate)) {
            return ResultBuilder.error("请求参数不能为空");
        }
        return ResultBuilder.success(new MerchantCreateRespVO());
    }
}
